← Index
NYTProf Performance Profile   
For flows_to_es.pl
  Run on Mon May 9 23:27:59 2016
Reported on Mon May 9 23:28:09 2016

Filename(eval 113)[/usr/share/perl5/Sub/Quote.pm:5]
StatementsExecuted 33 statements in 471µs
Eval Invoked At/usr/share/perl5/Sub/Quote.pm line 5
Sibling evals1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
22236µs1.56msSearch::Elasticsearch::Bulk::::new Search::Elasticsearch::Bulk::new
11112µs24µsSub::Quote::::BEGIN@5.42 Sub::Quote::BEGIN@5.42
1118µs8µsMethod::Generate::Constructor::::BEGIN@8.43Method::Generate::Constructor::BEGIN@8.43
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1{
222µs my $default_for__5flast_5fflush = ${$_[1]->{"\$default_for__5flast_5fflush"}};
31500ns my $default_for__5fbuffer = ${$_[1]->{"\$default_for__5fbuffer"}};
41200ns my $_QUOTED = ${$_[1]->{"\$_QUOTED"}};
5263µs234µs
# spent 24µs (12+11) within Sub::Quote::BEGIN@5.42 which was called: # once (12µs+11µs) by Sub::Quote::_clean_eval at line 5
no warnings 'closure';
# spent 24µs making 1 call to Sub::Quote::BEGIN@5.42 # spent 11µs making 1 call to warnings::unimport
6
# spent 1.56ms (36µs+1.52) within Search::Elasticsearch::Bulk::new which was called 2 times, avg 780µs/call: # once (6µs+1.50ms) by Search::Elasticsearch::Role::Client::Direct::Main::bulk_helper at line 56 of /opt/flows/lib/lib/perl5/Search/Elasticsearch/Role/Client/Direct/Main.pm # once (30µs+22µs) by Search::Elasticsearch::Role::Client::Direct::Main::bulk_helper at line 53 of Sub/Defer.pm
sub Search::Elasticsearch::Bulk::new {
7package Method::Generate::Constructor;
8
# spent 8µs within Method::Generate::Constructor::BEGIN@8.43 which was called: # once (8µs+0s) by Sub::Quote::_clean_eval at line 13
BEGIN {
911µs $^H = "2018";
101600ns ${^WARNING_BITS} = "\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\003";
1116µs %^H = (
12 );
131364µs18µs}
# spent 8µs making 1 call to Method::Generate::Constructor::BEGIN@8.43
141600ns my $class = shift;
151300ns $class = ref($class) if ref($class);
161200ns if ($class ne "Search::Elasticsearch::Bulk") {
17 if ($Moo::MAKERS{$class}) {
18 Moo->_constructor_maker_for($class,"Search::Elasticsearch::Bulk");
19 return $class->new(@_);
20 } elsif ($INC{"Moose.pm"} and my $meta = Class::MOP::get_metaclass_by_name($class)) {
21 return $meta->new_object($class->BUILDARGS(@_));
22 }
23 }
2412µs118µs my $args = $class->BUILDARGS(@_);
# spent 18µs making 1 call to Search::Elasticsearch::Role::Bulk::BUILDARGS
251500ns die "BUILDARGS did not return a hashref" unless ref($args) eq 'HASH';
2612µs if (my @missing = grep !exists $args->{$_}, qw(es)) {
27 die "Missing required arguments: ".join(', ', sort @missing);
28 }
2911µs my $new = bless({}, $class);;
3016µs12µs $new->{"_buffer"} = (
31 exists $args->{"_buffer"}
32 ? $args->{"_buffer"}
33 : $default_for__5fbuffer->($new)
34 );
351800ns $new->{"_buffer_count"} = (
36 exists $args->{"_buffer_count"}
37 ? $args->{"_buffer_count"}
38 : "0"
39 );
401500ns $new->{"_buffer_size"} = (
41 exists $args->{"_buffer_size"}
42 ? $args->{"_buffer_size"}
43 : "0"
44 );
451700ns if (exists $args->{"_bulk_args"}) {
46 $new->{"_bulk_args"} = $args->{"_bulk_args"};
47 }
4813µs12µs $new->{"_last_flush"} = (
49 exists $args->{"_last_flush"}
50 ? $args->{"_last_flush"}
51 : $default_for__5flast_5fflush->($new)
52 );
531300ns if (exists $args->{"_serializer"}) {
54 $new->{"_serializer"} = $args->{"_serializer"};
55 }
561600ns if (exists $args->{"es"}) {
57 $new->{"es"} = $args->{"es"};
58 }
591600ns $new->{"max_count"} = (
60 exists $args->{"max_count"}
61 ? $args->{"max_count"}
62 : "1000"
63 );
6411µs $new->{"max_size"} = (
65 exists $args->{"max_size"}
66 ? $args->{"max_size"}
67 : "1000000"
68 );
691500ns $new->{"max_time"} = (
70 exists $args->{"max_time"}
71 ? $args->{"max_time"}
72 : "0"
73 );
741500ns $new->{"on_conflict"} = (
75 exists $args->{"on_conflict"}
76 ? $args->{"on_conflict"}
77 : "0"
78 );
791200ns if (exists $args->{"on_error"}) {
80 $new->{"on_error"} = $args->{"on_error"};
81 }
821500ns $new->{"on_success"} = (
83 exists $args->{"on_success"}
84 ? $args->{"on_success"}
85 : "0"
86 );
871200ns if (exists $args->{"verbose"}) {
88 $new->{"verbose"} = $args->{"verbose"};
89 }
9014µs return $new;
91 }
9211µs $_QUOTED->[3] = \&Search::Elasticsearch::Bulk::new
93}
9416µs1;
95
96;